package com.leo.train.business.mapper;

import com.github.pagehelper.Page;
import com.leo.train.business.dto.TrainDto;
import com.leo.train.business.dto.TrainQueryDto;
import com.leo.train.business.entity.Train;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface TrainMapper {
    void insert(TrainDto trainDto);

    void update(TrainDto trainDto);

    Page<Train> pageQuery(TrainQueryDto trainQueryDto);

    Train selectById(Long id);

    Train selectByCode(String code);

    void deleteById(Long id);

    List<Train> selectAll();

}

